home *** CD-ROM | disk | FTP | other *** search
/ Aminet 25 / Aminet 25 (1998)(GTI - Schatztruhe)[!][Jun 1998].iso / Aminet / dev / misc / CGraphX_DevKit.lha / CGraphX / C / Include / cybergraphx / cybergraphics.h
Encoding:
C/C++ Source or Header  |  1998-03-09  |  6.3 KB  |  203 lines

  1. /*
  2. **    $VER: cybergraphics.h 41.18 (21.02.1998)
  3. **
  4. **    include file for cybergraphics.library
  5. **
  6. **    Copyright © 1996-1998 by phase5 digital products
  7. **      All Rights reserved.
  8. **
  9. */
  10.  
  11. #ifndef CYBERGRAPHX_CYBERGRAPHICS_H
  12. #define CYBERGRAPHX_CYBERGRAPHICS_H 1
  13.  
  14. #ifndef UTILITY_TAGITEM_H
  15. #include <utility/tagitem.h>
  16. #endif
  17.  
  18. #ifndef GRAPHICS_DISPLAYINFO_H
  19. #include <graphics/displayinfo.h>
  20. #endif
  21.  
  22.  
  23. #define CYBERGFXNAME    "cybergraphics.library"
  24. #define CYBERGFX_INCLUDE_VERSION  (41UL)
  25.  
  26. /*                                                          *
  27.  *  Definition of CyberModeNode (Returned in AllocModeList) *
  28.  *                                                          */
  29.  
  30. struct CyberModeNode
  31.  {
  32.   struct Node Node;
  33.   char   ModeText[DISPLAYNAMELEN];    /* name for this mode */
  34.   ULONG  DisplayID;            /* display id associated with the node */
  35.   UWORD  Width;                /* visible width */
  36.   UWORD  Height;            /* visible height */
  37.   UWORD  Depth;                /* display depth */
  38.   struct TagItem *DisplayTagList;    /* taglist with extended ModeID information */
  39.  };
  40.  
  41.  
  42. /*                                  *
  43.  * Parameters for GetCyberMapAttr() *
  44.  *                                  */
  45.  
  46. #define CYBRMATTR_XMOD        (0x80000001) /* function returns BytesPerRow if its called with this parameter */
  47. #define CYBRMATTR_BPPIX       (0x80000002) /* BytesPerPixel shall be returned */
  48. #define CYBRMATTR_DISPADR     (0x80000003) /* do not use this ! private tag */
  49. #define CYBRMATTR_PIXFMT      (0x80000004) /* the pixel format is returned */
  50. #define CYBRMATTR_WIDTH       (0x80000005) /* returns width in pixels */
  51. #define CYBRMATTR_HEIGHT      (0x80000006) /* returns height in lines */
  52. #define CYBRMATTR_DEPTH       (0x80000007) /* returns bits per pixel */
  53. #define CYBRMATTR_ISCYBERGFX  (0x80000008) /* returns -1 if supplied bitmap is a cybergfx one */
  54. #define CYBRMATTR_ISLINEARMEM (0x80000009) /* returns -1 if supplied bitmap is linear accessable */
  55.  
  56. /*                                 *
  57.  * Parameters for GetCyberIDAttr() *
  58.  *                                 */
  59.  
  60. #define CYBRIDATTR_PIXFMT (0x80000001) /* the pixel format is returned */
  61. #define CYBRIDATTR_WIDTH  (0x80000002) /* returns visible width in pixels */
  62. #define CYBRIDATTR_HEIGHT (0x80000003) /* returns visible height in lines */
  63. #define CYBRIDATTR_DEPTH  (0x80000004) /* returns bits per pixel */
  64. #define CYBRIDATTR_BPPIX  (0x80000005) /* BytesPerPixel shall be returned */
  65.  
  66. /*                              *
  67.  * Tags for CyberModeRequest()  *
  68.  *                              */
  69.  
  70. #define CYBRMREQ_TB          (TAG_USER+0x40000)
  71.  
  72. /*            *
  73.  * FilterTags *
  74.  *            */
  75.  
  76. #define CYBRMREQ_MinDepth    (CYBRMREQ_TB+0)  /* Minimum depth for displayed screenmode */
  77. #define CYBRMREQ_MaxDepth    (CYBRMREQ_TB+1)  /* Maximum depth  "       "        " */
  78. #define CYBRMREQ_MinWidth    (CYBRMREQ_TB+2)  /* Minumum width  "       "        " */
  79. #define CYBRMREQ_MaxWidth    (CYBRMREQ_TB+3)  /* Maximum width  "       "        " */
  80. #define CYBRMREQ_MinHeight   (CYBRMREQ_TB+4)  /* Minumum height "       "        " */
  81. #define CYBRMREQ_MaxHeight   (CYBRMREQ_TB+5)  /* Minumum height "       "        " */
  82. #define CYBRMREQ_CModelArray (CYBRMREQ_TB+6)
  83.  
  84. #define CYBRMREQ_WinTitle    (CYBRMREQ_TB+20)
  85. #define CYBRMREQ_OKText      (CYBRMREQ_TB+21)
  86. #define CYBRMREQ_CancelText  (CYBRMREQ_TB+22)
  87.  
  88. #define CYBRMREQ_Screen      (CYBRMREQ_TB+30)  /* Screen you wish the Requester to open on */
  89.  
  90. /*                            *
  91.  * Tags for BestCyberModeID() *
  92.  *                            */
  93.  
  94. #define CYBRBIDTG_TB  (TAG_USER+0x50000)
  95.  
  96. /* FilterTags */
  97.  
  98. #define CYBRBIDTG_Depth         (CYBRBIDTG_TB+0)
  99. #define CYBRBIDTG_NominalWidth  (CYBRBIDTG_TB+1)
  100. #define CYBRBIDTG_NominalHeight (CYBRBIDTG_TB+2)
  101. #define CYBRBIDTG_MonitorID     (CYBRBIDTG_TB+3)
  102. #define CYBRBIDTG_BoardName     (CYBRBIDTG_TB+5)
  103.  
  104. /*                                    *
  105.  * definition of divers pixel formats *
  106.  *                                    */
  107.  
  108. #define PIXFMT_LUT8    (0UL)
  109. #define PIXFMT_RGB15    (1UL)
  110. #define PIXFMT_BGR15    (2UL)
  111. #define PIXFMT_RGB15PC    (3UL)
  112. #define PIXFMT_BGR15PC    (4UL)
  113. #define PIXFMT_RGB16    (5UL)
  114. #define PIXFMT_BGR16    (6UL)
  115. #define PIXFMT_RGB16PC    (7UL)
  116. #define PIXFMT_BGR16PC    (8UL)
  117. #define PIXFMT_RGB24    (9UL)
  118. #define PIXFMT_BGR24    (10UL)
  119. #define PIXFMT_ARGB32    (11UL)
  120. #define PIXFMT_BGRA32    (12UL)
  121. #define PIXFMT_RGBA32    (13UL)
  122.  
  123. /*                                                        *
  124.  * SrcRectangle formats defines for xxxPixelArray calls() * 
  125.  *                                                        */
  126.  
  127. #define RECTFMT_RGB    (0UL)
  128. #define RECTFMT_RGBA    (1UL)
  129. #define RECTFMT_ARGB    (2UL)
  130. #define RECTFMT_LUT8    (3UL)
  131. #define RECTFMT_GREY8    (4UL)
  132.  
  133. /*                                    *
  134.  * Parameters for CVideoCtrlTagList() *
  135.  *                                    */
  136.  
  137. #define SETVC_DPMSLevel  (0x88002001)
  138.  
  139. #define DPMS_ON      (0UL)   /* Full operation                             */
  140. #define DPMS_STANDBY (1UL)   /* Optional state of minimal power reduction  */
  141. #define DPMS_SUSPEND (2UL)   /* Significant reduction of power consumption */
  142. #define DPMS_OFF     (3UL)   /* Lowest level of power consumption          */
  143.  
  144. /*                              *
  145.  * Tags for LockBitMapTagList() *
  146.  *                              */
  147.  
  148. #define LBMI_WIDTH       (0x84001001)
  149. #define LBMI_HEIGHT      (0x84001002)
  150. #define LBMI_DEPTH       (0x84001003)
  151. #define LBMI_PIXFMT      (0x84001004)
  152. #define LBMI_BYTESPERPIX (0x84001005)
  153. #define LBMI_BYTESPERROW (0x84001006)
  154. #define LBMI_BASEADDRESS (0x84001007)
  155.  
  156. /*                                *
  157.  * Tags for UnLockBitMapTagList() *
  158.  *                                */
  159.  
  160. #define    UBMI_UPDATERECTS    (0x85001001)
  161. #define    UBMI_REALLYUNLOCK    (0x85001002)
  162.  
  163.  
  164.  
  165. /*                                *
  166.  * Message passed to the DoCDrawMethodTagList() hook function    *
  167.  *                                */
  168.  
  169.  
  170. struct  CDrawMsg
  171. {
  172.         APTR    cdm_MemPtr;
  173.         ULONG   cdm_offx;
  174.         ULONG   cdm_offy;
  175.         ULONG   cdm_xsize;
  176.         ULONG   cdm_ysize;
  177.         UWORD   cdm_BytesPerRow;
  178.         UWORD   cdm_BytesPerPix;
  179.         UWORD   cdm_ColorModel;
  180. };
  181.  
  182. /*                            *
  183.  * Colour Table source formats for WriteLUTPixelArray()    *
  184.  *                            */
  185.  
  186. #define CTABFMT_XRGB8    (0UL)    /* ULONG [] table */
  187.  
  188.  
  189. /*                            *
  190.  *    graphics.library/AllocBitMap() extended flags    *
  191.  *                            */
  192.  
  193. #ifndef BMB_SPECIALFMT
  194. #define BMB_SPECIALFMT (7UL)
  195. #define BMF_SPECIALFMT (1UL << BMB_SPECIALFMT)
  196. #endif /* BMB_SPECIALFMT */
  197.  
  198. #define SHIFT_PIXFMT( fmt ) (((ULONG)(fmt)) << 24UL)
  199.  
  200.  
  201.  
  202. #endif  /* !CYBERGRAPHX_CYBERGRAPHICS_H */
  203.